The present invention relates to high performance texture mapping in a graphics processor. More specifically, the invention relates to a method and apparatus for maintaining the consistency of state variables used by parallel texture pipelines in a multi-pipeline texture engine, regardless of whether the texture engine is processing a single texture or a blend of different textures.
As is known, a graphics processor may be organized as a pipeline, comprising a sequence of processing elements that together generate a picture image composed of graphics objects. The specific processing elements of a pipelined graphics processor may vary. A pipelined graphics processor may contain a texture engine for the purpose of applying textures to the surfaces of graphics polygons. The individual components of a texture engine may themselves be arranged in a pipeline as well, thereby achieving additional efficiency. Such pipelined texture engines may be programmed using state variables. As each polygon moves through the various stages of the texture engine pipeline, the values of the programmer-supplied state variables may determine the specific textures to be used by the pipeline, as well as the individual texture operations the texture engine may perform to process the polygon. The final product of a texture engine may consist of an output stream of texels corresponding to the picture elements of texture-mapped polygons.
For an extended treatment on methods of graphics visualization and texture mapping, see Foley, van Dam, et al., Computer Graphics—Principles and Practice (2d Ed. 1990 Addison Wesley, corr. 1995).
The process of scaling a texture in order to apply it to a polygon surface may be computationally expensive. Accordingly, it is known in the art to provide several different versions of a texture map, each associated with a different level of detail. These different texture levels typically are developed in advance, so they may be available as needed. During rendering operations, the graphics system may select a texture level most suitable for rendering a particular polygon surface so as to reduce the complexity of texture scaling operations. Once a level of texture detail has been selected, any of a number of techniques known in the art may be used to filter and map the texture to the polygon surface.
Multi-texturing is a general technique known in the art for blending textures together to create a multi-textured effect. Linear filtering and trilinear filtering are examples of multi-texturing techniques that blend adjacent levels of the same texture. As is also known, entirely different textures may also be blended to create a variety of visual effects.
A conventional single texture pipeline may implement texture blending by providing appropriate state variable programming capabilities corresponding to individual texture operations. In these single texture pipeline architectures, only one texture effect may be processed at a time. Therefore, multi-texturing effects may be implemented in single texture pipeline systems by processing the desired combination of texture operations serially.
To improve the processing speed of multi-texturing operations, separate texture pipelines may be configured to operate in parallel. In such a multiple texture pipeline architecture, each individual texture pipeline may apply a different texture to the same polygon at substantially the same time. Alternatively, each texture pipeline may simultaneously apply a different level of detail of the same texture to a polygon.
Because each individual texture pipeline in a multiple texture pipeline architecture may be capable of operating independently, separate state variable programming interfaces and control signals may be required to manage each individual pipeline. However, the additional state variable interfaces and control signals of multiple texture pipelines require an added level of complexity over the corresponding interfaces and control signals found in single texture pipelines. Additionally, graphics software that has been designed to utilize a single texture pipeline interface may be ineffective or inoperable in a multiple texture pipeline architecture.
Accordingly, there is a need in the art for a technique to support a multiple texture pipeline architecture using the same programming and control interface that supports a single texture pipeline architecture. More specifically, there is a need in the art for a technique to maintain the consistency of control signals and programmer-supplied state variables that together control the operation of independent texture pipelines in a multiple texture pipeline architecture using a single texture pipeline software interface. Additionally, there is a need in the art to maintain the consistency of state variables used by independent texture pipelines, while allowing a programmer to create all possible sequences of single texture and multiple texture effects. Finally, there is a need in the art for a mechanism that reduces power consumed by multiple texture pipelines when only a single texture pipeline is required.